package com.insigma.config;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.ObjectMapper;

import java.text.SimpleDateFormat;

/**
 *
 */
public class JacksonConfig extends ObjectMapper {
    public JacksonConfig() {
        super();
        super.setDateFormat(new SimpleDateFormat("yyyy-MM-dd"));
        super.setSerializationInclusion(JsonInclude.Include.NON_NULL);
        super.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
    }
}
